\documentclass[E:/GsjzTle/main/main.tex]{subfiles}

\begin{document}

\begin{lstlisting}
void insert(vector<int>vec)
{
	int root = 0;
	for(auto i : vec)
	{
		if(!tree[root][i]) sum1[root] ++ , tree[root][i] = ++ tot , rt[root].pb(i);
		root = tree[root][i];
	}
} 
void query(vector<int>vec)
{
	int root = 0;
	for(auto i : vec)
	{
		sum2[root] = 1;
		if(!tree[root][i]) return ;
		root = tree[root][i];
	}
}
void del(int root)
{
	for(auto i : rt[root])
	{
		del(i);
		tree[root][i] = 0;
	} 
	rt[root].clear();
}
\end{lstlisting}

\end{document}
